import configparser

def UpdateConfig(engine_path, project_path, project_name, project, git_Username, clientconfig, platform):
    config = configparser.ConfigParser()

    config.add_section('EngineInfo')
    config.set('EngineInfo', 'engine_path', engine_path)

    config.add_section('ProjectInfo')
    config.set('ProjectInfo', 'project_path', project_path)
    config.set('ProjectInfo', 'project_name', project_name)
    config.set('ProjectInfo', 'project', project_path + "/" + project_name + "/" + project_name + ".uproject")

    config.add_section('UserInfo')
    config.set('UserInfo', 'git_Username', git_Username)

    config.add_section('BuildInfo')
    config.set('BuildInfo', 'clientconfig', clientconfig)
    config.set('BuildInfo', 'platform', platform)

    with open('../Config/config.ini', 'w') as config_file:
        config.write(config_file)
